package com.gxks.lhs.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 聊天信息表
 * </p>
 *
 * @author LuoHaisong
 * @since 2023-05-18
 */
@Getter
@Setter
@Accessors(chain = true)
@ApiModel(value = "Chat对象", description = "聊天信息表")
public class Chat implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    @ApiModelProperty("聊天信息ID，主键")
    private Integer chatId;

    @ApiModelProperty("发送者ID")
    private Integer senderId;

    @ApiModelProperty("接收者ID")
    private Integer receiverId;

    @ApiModelProperty("消息内容")
    private String message;

    @TableField(fill = FieldFill.INSERT)
    @ApiModelProperty("发送时间")
    private LocalDateTime sendTime;


}
